package myrecyclerview

import android.view.LayoutInflater
import android.view.ViewGroup
import com.yannuo.myrecyclerview.databinding.ItemTextBinding

/**
 * @dsc     简介
 * @Author  LiWeiZhong
 * @Date    2025/6/21 9:38
 * @Version 1.0
 */
class ItemAdapter : BaseAdapter<String, ItemTextBinding>(){
    override fun getB(inflater: LayoutInflater, parent: ViewGroup): ItemTextBinding {
        return ItemTextBinding.inflate(inflater, parent, false)
    }

    override fun addEventListener(holder: Holder) {

    }

    override fun bindHolder(holder: Holder, position: Int) {
        getData(position).apply {
            holder.binding.tv.text = this
        }
    }
}